﻿using System;
using System.Collections.Generic;
using System.Text;
using Pixysoft.Framework.Reflection;
using Pixysoft.Weblications.Sango.Dao;
using Pixysoft.Weblications.Sango.Constant;

namespace Pixysoft.Weblications.Sango.Command.building
{
    partial class SangoBuildingHandler
    {
        public building_queuebuyinfo building_queuebuyinfo()
        {
            string userCode = SangoManager.Authentication();

            building_queuebuyinfo response = ReflectionManager.CreatePojo<building_queuebuyinfo>();
            response.Succeed = false;

            Entities.Sys_Queue sysQueue = UsrQueueDao.getAvailableSysQueue(userCode, CtiQueueTypecodeCollection.BUILDING_UPGRADE);

            if (sysQueue == null)
            {
                response.Message = "无可扩展的队列";
                return response;
            }

            response.goldprice = sysQueue.Goldprice;
            response.Succeed = true;
            return response;
        }


    }
    public interface building_queuebuyinfo : ISangoResponse
    {
        long goldprice { get;set;}
    }
}
